#include <stdio.h>
#include <unistd.h>

int main(){
    pid_t pid = fork();

    if (pid == 0) {
        sleep(1);
        printf("I am son(%d)\n", pid);
        printf("son pid(%d)\n", getpid());
        printf("my father pid(%d)\n", getppid());
    } else {
        printf("I am father(%d)\n", getpid());
        printf("myson pid(%d)\n", pid);
    }
}
